package com.woniuxy.project115.kaer.user.util;

public class RedisKey {
    //短信验证码注册key
    public static  String REGISTER_CODE_KEY(String phone)throws Exception{
        return "register:code:phone:"+phone;
    }
    //验证一分钟内是否发送过验证码
    public static  String REGISTER_CODE_STATE(String phone)throws Exception{
        return "register:code:state:phone:"+phone;
    }
    //短信登录验证码key
    public static  String LOGIN_CODE_KEY(String phone)throws Exception{
        return "login:code:phone:"+phone;
    }
    //验证一分钟内是否发送过验证码
    public static  String LOGIN_CODE_STATE(String phone)throws Exception{
        return "login:code:state:phone:"+phone;
    }
    //保存短token
    public static String ACCESS_EXPIRE(String accessToken)throws Exception{
        return "access:expire:"+accessToken;
    }
    //保存长token
    public static String ACCESS_REFRESH(String accessToken)throws Exception{
        return "refresh:expire:"+accessToken;
    }
    //保存用户权限列表
    public static String USER_PERMISSION_LIST(Integer userId)throws Exception{
        return "user:permission:list:userid"+userId;
    }

    public static String SEND_STATE(String mobile)throws Exception {
        return "send:state:mobile:"+mobile;
    }
}
